/**
 * This class is to generate a date time in Chinese Format.
 */
package jspClass;

//import java.util.Calendar;
import java.util.GregorianCalendar;
import java.text.SimpleDateFormat;

/**
 * @author Wilbur
 *
 */
public class ChineseDate {
	private GregorianCalendar gCalendar = null;
	
	public ChineseDate(){
		gCalendar = new GregorianCalendar();
	}
	
	public void setDateTime(int y, int m, int d, int h, int mm){
		gCalendar = new GregorianCalendar(y,m,d,h,mm);
	}
	
	public String getDateTimeString(){
		SimpleDateFormat sdf;
		sdf = new SimpleDateFormat("yyyy-M-d a hh:m:s");
		return sdf.format(gCalendar.getTime());
	}
}
